package com.yjd.comm.funds.enums;

/**
 * Created by yjd-wap on 2017/9/19.
 */
public enum RechSourceEnum {

    UNKNOWN(0, "未知"),
    ANDROID(1, "android"),
    IOS(2, "ios"),
    BACK(3, "后台管理");
    private int code;
    private String label;

    public static RechSourceEnum parse(int code){
        for (RechSourceEnum orderSourceEnum : RechSourceEnum.values()) {
            if(orderSourceEnum.getCode() == code){
                return orderSourceEnum;
            }
        }
        return null;
    }

    private RechSourceEnum(int code, String label) {
        this.code = code;
        this.label = label;
    }

    public int getCode() {
        return code;
    }
    public void setCode(int code) {
        this.code = code;
    }
    public String getLabel() {
        return label;
    }
    public void setLabel(String label) {
        this.label = label;
    }
}
